home *** CD-ROM | disk | FTP | other *** search
/ Super PC 34 / Super PC 34 (Shareware).iso / spc / UTIL / DJGPP2 / V2 / DJTST200.ZIP / tests / libc / posix / unistd / sleep.c < prev    next >
Encoding:
C/C++ Source or Header  |  1995-03-20  |  250 b   |  21 lines

  1. #include <stdlib.h>
  2. #include <stdio.h>
  3. #include <time.h>
  4. #include <unistd.h>
  5.  
  6. int
  7. main(void)
  8. {
  9.   time_t t;
  10.  
  11.   time(&t);
  12.   printf("start: %s", ctime(&t));
  13.  
  14.   sleep(10);
  15.  
  16.   time(&t);
  17.   printf("end  : %s", ctime(&t));
  18.  
  19.   return 0;
  20. }
  21.